package com.bawei.lib_net.storage


import com.bawei.lib_net.storage.utils.MMKVOwner
import com.bawei.lib_net.storage.utils.MMKVProperty
import com.tencent.mmkv.MMKV

/**
 *作者：lxy
 *功能:
 *时间：2025/5/25
 */
object AuthMMKV : MMKVOwner {

    //  MMKV实例 auth文件中
    override val mmkv: MMKV
        get() = MMKV.mmkvWithID("auth")

    //token
    var token by MMKVProperty("")

    //accessId
    var accessId by MMKVProperty("696a3fe8703f4dadbf1f8d743916f356")

    //uId
    var uId by MMKVProperty("")

    //username
    var username by MMKVProperty("")

    fun hasLogin() = token.isNotEmpty()
}